package com.ma.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;
import lombok.experimental.Accessors;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * @ProjectName: project
 * @Package: com.ma.entity
 * @ClassName: Project
 * @Author: YHHHH
 * @Description: 课题表
 * @Date: 2021/3/4 22:50
 * @Version: 1.0
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
@ToString
@TableName("project")
@Accessors(chain = true)
public class Project implements Serializable {

    @TableId(value = "id",type = IdType.AUTO)
    private Integer projectId;  //课程号

    @TableField("name")
    private String projectName; //课程名

    @TableField("tId")
    private Integer teacherId; //老师Id

    @TableField("start")
    @DateTimeFormat(pattern = "yyyy-MM-dd' 'HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date startDate;     //开始时间

    @TableField("end")
    @DateTimeFormat(pattern = "yyyy-MM-dd' 'HH:mm:ss")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date endDate;       //结束时间

    @TableField("content")
    private String content;     //课题详情

    @TableField("mid")
    private Integer majorId;    //专业号

    private Teacher teacher;    //指导老师

    private Team team;          //所属小组

    private Major projectMajor;     //专业

}
